thirdparty_root :=./../StaticLib
LASTSO:=libADDADD.so
CC := g++

INCS += -I${thirdparty_root}

LIBS += ${thirdparty_root}/libADD.a

AFLAGS := -Wall -c -fPIC -O2 -std=c++11 $(INCS)
LDFLAGS := -lpthread 
LDFLAGS += -Wl,-rpath,${thirdparty_root}

OBJS := $(patsubst %.cpp,%.o,$(shell find . -name "*.cpp"))

$(warning $(OBJS))
$(LASTSO): $(OBJS)
	$(CC)  -shared -o $@ $^ $(LDFLAGS) $(LIBS)

$(OBJS): %.o:%.cpp
	$(CC) $(AFLAGS) $^ -o $@

debugOBJS:
	@echo ${OBJS}

.PHONY: clean FaceFilter setenv

clean:					
	rm -rf *.o *.so *.a
